<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
   "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
	<title>Kepler: The Lua Web Development Platform</title>
    <link rel="stylesheet" href="http://www.keplerproject.org/doc.css" type="text/css"/>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
</head>

<body>

<div id="container">

<div id="product">
	<div id="product_logo"><a href="http://www.keplerproject.org">
		<img alt="Kepler" src="kepler.png"/>
	</a></div>
	<div id="product_name"><big><strong>Kepler</strong></big></div>
	<div id="product_description">The Lua Web Development Platform</div>
</div> <!-- id="product" -->

<div id="main">
	
<div id="navigation">
<h1>Kepler</h1>
	<ul>
		<li><a href="index.html">Home</a>
			<ul>
				<li><a href="index.html#overview">Overview</a></li>
				<li><a href="index.html#status">Status</a></li>
				<li><a href="index.html#download">Download</a></li>
				<li><a href="index.html#history">History</a></li>
				<li><a href="index.html#credits">Credits</a></li>
				<li><a href="index.html#contact">Contact us</a></li>
			</ul>
		</li>
		<li><a href="install.html">Installation</a>
            <ul>
                <li><a href="install.unix.html">Unix/OSX</a>
                    <ul>
                        <li><a href="install.unix.html#introduction">Introduction</a></li>
                        <li><a href="install.unix.apache2.html">Apache 2</a></li>
                        <li><strong>Lighttpd</strong></li>
                        <li><a href="install.unix.xavante.html">Xavante</a></li>
                    </ul>
                </li>
                <li><a href="install.windows.html">Windows</a></li>
            </ul>
        </li>
        <li><a href="manual.html">Manual</a>
			<ul>
				<li><a href="manual.html#introduction">Introduction</a></li>
				<li><a href="manual.html#configuration">Configuration</a></li>
			</ul>
		</li>
		<li><a href="reference.html">Reference</a></li>
		<li><a href="examples.html">Examples</a></li>
        <li><a href="http://luaforge.net/projects/kepler/">Project</a>
            <ul>
                <li><a href="bugtracker.html">Bug Trackers</a></li>
                <li><a href="http://luaforge.net/scm/?group_id=104">CVS</a></li>
            </ul>
        </li>
		<li><a href="license.html">License</a></li>
	</ul>
</div> <!-- id="navigation" -->

<div id="content">

<h2>Using Kepler with Lighttpd in Unix</h2>

<p>You can configure Kepler with <a href="http://www.lighttpd.net/">Lighttpd</a>
with the following launchers:</p>

<ul>
	<li><a href="#fastcgi">FastCGI</a></li>
	<li><a href="#cgi">CGI</a></li>
</ul>

<p>Please check the corresponding launcher section for the configuration details.</p>


<h2><a name="fastcgi"></a>FastCGI</h2>

<p>FastCGI is a good option for Kepler on an Lighttpd Server. To use Kepler as a FastCGI
application, you have to configure Lighttpd to associate <code>.lua</code> and <code>.lp</code>
extensions with the Kepler FastCGI launcher (<code>/usr/local/bin/fastcgi</code> in the default
installation). Edit the Lighttpd configuration file to include the following:</p>

<pre class="example">
server.modules = ( "mod_fastcgi" )

server.document-root = ( "/usr/local/kepler/web" )

fastcgi.server = ( ".lua" =>

                   ( "kepler" =>
                     ( "socket" => "/tmp/kepler-fastcgi.socket",
                       "bin-path" => "/usr/local/bin/fastcgi",
                     )
                   ),
                   ".lp" =>
                   ( "kepler" =>
                     ( "socket" => "/tmp/kepler-fastcgi.socket",
                       "bin-path" => "/usr/local/bin/fastcgi",
                     )
                   )
                  )

</pre>

<p>Now run Lighttpd with</p>

<pre class="example">
lighttpd -f lighttpd.conf
</pre>

<p>
and all requests to <code>.lua</code> and <code>.lp</code> files will go through Kepler.
Please check the <a href="http://www.lighttpd.net/">Lighttpd documentation</a> for extra
configuration options.
</p>

<h2><a name="cgi"></a>CGI</h2>

<p>Kepler can be used as a standard Lighttpd CGI application.</p>

<p>This part of the documentation is still under development.</p>

</div> <!-- id="content" -->

</div> <!-- id="main" -->

<div id="about">
	<p><a href="http://validator.w3.org/check?uri=referer">Valid XHTML 1.0!</a></p>
	<p><small>$Id: install.unix.lighttpd.html,v 1.3 2007/11/19 20:22:03 hisham Exp $</small></p>
</div> <!-- id="about" -->

</div> <!-- id="container" -->

</body>
</html>










